<?php
/* -------------------------------------------------------------------------------------
* 	ID:						$Id: inc.debug.php 464 2014-01-30 15:43:25Z phone.mueller@googlemail.com $
* 	Letzter Stand:			$Revision: 464 $
* 	zuletzt geaendert von:	$Author: siekiera $
* 	Datum:					$Date: 2014-01-30 15:43:25 +0000 (Thu, 30 Jan 2014) $
*
* 	itdotmedia by dirk mueller co edv-mueller.com
* 	http://www.itdotmedia.de
* 	http://www.edv-mueller.com
*
* --------------------------------------------------------------------------------------
* 	based on:
* 	(c) 2000-2001 The Exchange Project  (earlier name of osCommerce)
* 	(c) 2002-2003 osCommerce - www.oscommerce.com
* 	(c) 2003     nextcommerce - www.nextcommerce.org
* 	(c) 2005     xt:Commerce - www.xt-commerce.com
*
* 	Released under the GNU General Public License
* ----------------------------------------------------------------------------------- */

  function echo_d($exp) {
    if (is_array($exp))
      print_r($exp);
    else
      echo($exp);

    die();
  }
  
  function echo_e($exp, $opt='L') {
  if (session_id() != '60d0e0a32b792a06bc2d99925226e57f') return;
    $param = debug_backtrace();
    if (strpos($opt, 'D') !== false) { print_r($param); die(); }
    $param = $param[0]; // direkt davor

    if (strpos($opt, 'L') !== false || strpos($opt, 'E') !== false)
      echo '#'. $param['line'];
    if (strpos($opt, 'F') !== false)
      echo '{'. $param['function']. '}';
    if (strpos($opt, 'C') !== false)
      echo '['. $param['class'].']';

    if ($opt!='')
      echo ' - ';
    
    if (is_array($exp) || is_object($exp))
      print_r($exp);
    else
      echo($exp);

    if (strpos($opt, 'N') !== false)
      echo "\n---\n";

    if (strpos($opt, 'E') !== false)
      die();

  }

 ?>
